<template>
  <el-table
    :data="reset"
    border
    @selection-change="change"
    style="width: 100%">
    <el-table-column
      type="selection"
      width="55">
    </el-table-column> 
    <el-table-column
      prop="Hid"
      label="序号"
      width="100">
      <template slot-scope="scope">
        <span v-show="scope.row.MessageStatu==1"><i class="el-icon-edit"></i>{{scope.row.Hid}}</span>
        <span v-show="scope.row.MessageStatu==0"><i class="el-icon-share"></i>{{scope.row.Hid}}</span>
      </template>
    </el-table-column>
    <el-table-column
      prop="ChatTypeFormat"
      label="消息类型"
      width="180">
    </el-table-column>
    <el-table-column
      prop="Message"
      label="消息内容">
    </el-table-column>
    <el-table-column
      prop="PriorityCodeFormat"
      label="紧急程度">
    </el-table-column>
    <el-table-column
      prop="UserName"
      label="发送人">
    </el-table-column>
    <el-table-column
      prop="CreateTime"
      label="发送时间">
    </el-table-column>
  </el-table>
</template>

<script>
  export default {
    props:{
        reset:{
          type:Array,
          required:true
        }
      },
    data() {
      return{

      }
    },
    methods:{
      change(val){
          let listId=[]
          val.forEach(el => {
              listId.push(el.Hid)
          });
          this.$emit('getId',listId)
        },
        handleDelete(){
          this.$parent.dialogVisible=true
        }
    }
  }
</script>